<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib uri="/struts-tags" prefix="s" %>
<%@ taglib uri="/WEB-INF/tld/frsf.tld" prefix="frsf"%>
<%@ taglib uri="http://www.opensymphony.com/oscache" prefix="oscache" %> 
<%@include file="/htmlframe/jsp/common.jsp"%>
<%@page import="com.gcxx.framework.security.entity.FrsfUser"%>
<%@page import="org.springframework.security.context.SecurityContext"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%
	SecurityContext securityContext = (SecurityContext)request.getSession().getAttribute("SPRING_SECURITY_CONTEXT");
    FrsfUser user = null;
    String menuJson = null;
	if (securityContext != null
			&& securityContext.getAuthentication() != null) {
		user = (FrsfUser)securityContext.getAuthentication().getPrincipal();
	}
	if(user == null){
		try {
			response.sendRedirect(basePath + "logout");
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
%>
<html>
<head>
<title><s:text name="title"></s:text></title>
<oscache:cache time="-1" scope="session">
<script language="javascript" src="<%=hf_jsPath %>/lodop/LodopFuncs.js"></script>
<script>
var basePath='<%=basePath%>';
//js工具类
var tl = new Tools();
//js统一校验工具
var vc = new Verifier();
</script>
<script type="text/javascript" src="<%=basePath%>isc/js/wards/WardsDspnmInfo/drug_summary.js">
</script>
<style type="text/css">
 	body{padding: 2px 2px 2px 2px;margin:0px;}
	.textAlign{vertical-align: middle;}
</style>
</oscache:cache>
</head>
<body>
<div class="easyui-panel" title="查询条件" style="width: 100%;border-bottom-width: 0px;">
		<table style="width: 100%">
		<tr>
			<td colspan="2">
				<label>应执行时间：</label>
			<input type="text" style="width:150px;" id="beginTime" class="Wdate" readonly="readonly" onClick="WdatePicker({el:'beginTime', dateFmt:'yyyy-MM-dd HH:mm',maxDate:'#F{$dp.$D(\'endTime\');}'})"/>
           ~ <input type="text" style="width:150px;" id="endTime"   class="Wdate" readonly="readonly" onClick="WdatePicker({el:'endTime', dateFmt:'yyyy-MM-dd HH:mm',minDate:'#F{$dp.$D(\'beginTime\');}'})"/>
			</td>
			<td>
				<label>病区：</label>
				<select name="stationCode" style="width:150px" id="stationCode" >
				</select>
			</td>
			<td>
				<label>汇总状态：</label>
				<frsf:select name="sumState" id="sumState" canEdit="true" type="4" selectedValue="1" style="width:80px;"></frsf:select>
			</td>
		</tr>
		<tr>
			
			<td align="center" colspan="4"><a href="javascript:void(0)" onclick="doSearch()" class="easyui-linkbutton" data-options="iconCls:'icon-search'" style="width:80px">查询</a></td>
		</tr>
		</table>
</div>
<oscache:cache time="-1" scope="session">
<table id="station"></table>	

<div class="easyui-panel" title="操作信息" style="width: 100%;border-bottom-width: 0px;border-top-width:0px;">
		<table >
			<tr>
			
			<td >
				
				<lablel >静注：<input type="checkbox" class="textAlign" name="routCode" id="routCode2" checked="checked" value="2"  onclick="changeRoutCode()"/></lablel>&nbsp;&nbsp;&nbsp;&nbsp;
				<lablel >肌注：<input type="checkbox" class="textAlign" name="routCode" id="routCode3"  checked="checked" value="3" onclick="changeRoutCode()"/></lablel>&nbsp;&nbsp;&nbsp;&nbsp;
				<lablel >口服：<input type="checkbox" class="textAlign" name="routCode" id="routCode1"  checked="checked" value="1" onclick="changeRoutCode()" /></lablel>&nbsp;&nbsp;&nbsp;&nbsp;
				<!-- <lablel >其它：<input type="checkbox" class="textAlign" name="routCode" id="routCode4"  checked="checked" value="4" onclick="changeRoutCode()" /></lablel> -->
			</td>
			<td  align="right" style="padding-left: 20px;"><a href="javascript:void(0)" onclick="doPrint()" class="easyui-linkbutton" data-options="iconCls:'icon-print'" style="width:80px">打印</a></td>
			</tr>
		</table>
</div>
<div class="easyui-panel" style="width: 100%;margin: 0px;padding: 0px;" >
	<table border="0" width="100%" id="tableDataes">
		<tr>
			<td width="55%">
				<table id="drugGrid" title="病区药品汇总信息"></table>
			</td>
			<td width="45%" >
				<table id="patientGrid" title="病患用药信息" ></table>
			</td>
		</tr>
	</table>
</div>
<div id="div1" style="display:none">
<div style="LINE-HEIGHT: 30px" class=size18 align=center><strong><font size="5">汇总单</font></strong></div>
<table border="0" cellSpacing="0" cellPadding="0" width="100%">
  <tbody>
  <tr>
    <td width="43%" colspan="3"><font>所属病区：<span id="dept"></span></font></td>
  </tr>
  <tr>
    <td><font>汇总单号：<span id="gatherId"></span></font><font></font></td>
    <td><font>汇总人：<span id="optUser"><%=user.getEmpName() %></span></font></td> 
    <td><font>打印时间：<span id="printTime"></span></font></td>
  </tr>
  </tbody>
</table>
</div>
<object  id="LODOP_OB" classid="clsid:2105C259-1E0C-4534-8141-A753534CB4CA" width=0 height=0> 
<embed id="LODOP_EM" type="application/x-print-lodop" width=0 height=0></embed>
</object>
</oscache:cache>
</body>
</html>
